﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<ProjectDirector.ViewModels.CustomerViewModel>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
    Details
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

<table width="100%" style="border-bottom-style: solid; border-bottom-width: 1px; border-bottom-color: #C0C0C0"><tr><td style="width:55px;">
<img src="../../Content/Images/bigimgs/158.png" width="50px" height="50px" alt="" /></td>
<td><span style="font-size:14px; font-weight:bold;">Customer Details</span>
<div style="float:right;"><%:Html.ActionLink("Add Contact", "Create", "Contact", new { id = Model.Customer.CustomerId },null)%> | 
<%:Html.ActionLink("Contact List","ContactList","Contact",new { id = Model.Customer.CustomerId },null) %> | 
<%:Html.ActionLink("Create Project","Create","Project") %> |
<%: Html.ActionLink("Back to List", "Index") %>
</div>
</td></tr>
</table> 

<table width="100%" style="table-layout:fixed;"><tr><td style="width: 132px">CompanyName</td><td><%: Html.DisplayFor(model => model.Customer.CompanyName) %></td></tr>
    <tr><td style="width: 132px">BusinessType</td><td><%: Html.DisplayFor(model => model.Customer.BusinessType.BusinessTypeName) %></td></tr>
    <tr><td style="width: 132px">Telephone</td><td><%: Html.DisplayFor(model => model.Customer.Telephone) %></td></tr>
    <tr><td style="width: 132px">Email</td><td><%: Html.DisplayFor(model => model.Customer.Email) %></td></tr>
    <tr><td style="width: 132px">Fax Number</td><td><%: Html.DisplayFor(model => model.Customer.FaxNumber) %></td></tr>
    <tr><td style="width: 132px">Web Site</td><td> <%: Html.DisplayFor(model => model.Customer.WebSite) %></td></tr>    
     <tr><td style="text-decoration: underline; width: 132px"><strong>Address</strong></td><td></td></tr>
     <tr><td style="width: 132px">Number / House Name</td><td><%:Html.DisplayFor(m=>m.Address.AddressId) %></td></tr>
     <tr><td style="width: 132px">Street</td><td><%:Html.DisplayFor(m=>m.Address.Address2) %></td></tr>
     <tr><td style="width: 132px">Town</td><td><%:Html.DisplayFor(m=>m.Address.Town) %></td></tr>
     <tr><td style="width: 132px">Post Code</td><td><%:Html.DisplayFor(m=>m.Address.PostalCode) %></td></tr>
     <tr><td style="width: 132px">Country:</td><td><%:Html.DisplayFor(m=>m.Address.Country.CountryName) %></td></tr>     
</table> 
<br />
<table width="100%" class="TableLines">
<tr><td style="background-color: #C0C0C0">Audit Details</td></tr>
<tr><td>
 <div class="display-label">Created By</div>
    <div class="display-field">
        <%: Model.CreatedByName %>
    </div>

    <div class="display-label">Date Created</div>
    <div class="display-field">
        <%: Html.DisplayFor(model => model.Customer.DateCreated)%>
    </div>

    <div class="display-label">Updated By</div>
    <div class="display-field">
        <%: (!string.IsNullOrEmpty(Model.UpdatedByName)? Model.UpdatedByName : string.Empty) %>
    </div>

    <div class="display-label">Date Updated</div>
    <div class="display-field">
        <%: Html.DisplayFor(model => model.Customer.DateUpdated)%>
    </div>
    </td></tr>
</table>
</asp:Content>
